<template>
	<view>
		<view class="border-top">

		</view>
		<!-- <view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				设备名称
			</view>
			<view style="color: #474747;">
				{{device_detal_list.equipmentName}}
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				设备编号
			</view>
			<view style="color: #474747;">
				{{device_detal_list.equipmentNumber}}
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				所在位置
			</view>
			<view style="color: #474747;">
				{{device_detal_list.position}}
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				所属单位
			</view>
			<view style="color: #474747;">
				{{device_detal_list.deptname}}
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				状态
			</view>
			<view style="color: #474747;">
				{{device_detal_list.status==0?'正常':device_detal_list.status==1?'异常':'异常'}}
			</view>
		</view> -->
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				设备类型
			</view>
			<view style="color: #474747;">
				{{device_detal_list.equipmenttype}}
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				设备型号
			</view>
			<view style="color: #474747;">
				{{device_detal_list.equipmentmodel}}
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				所属建筑
			</view>
			<view style="color: #474747;">
				{{device_detal_list.buildingname}}
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				楼层
			</view>
			<view style="color: #474747;">
				需要接口
			</view>
		</view>
		<view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				位置描述
			</view>
			<view style="color: #474747;">
				{{device_detal_list.address}}
			</view>
		</view>
		<!-- 		<view>
			<image src="../../static/image/tishi.png" mode="widthFix"
				style="width: 490rpx;height: 194rpx;margin-left: 32%;"></image>
		</view> -->
		<!-- <view class="d-flex j-sb p-3 main-text-color_2 font flex-1  border-bottom pb-4"
			style="width: 83%;margin: 0 auto;">
			<view class="main-text-color">
				位置描述
			</view>
			<input type="text" value="" placeholder="请输入位置描述" placeholder-style="margin-left:100rpx"
				@input="input_position" />
		</view> -->
	</view>
</template>

<script>
	export default {
		data() {
			return {
				input_text: '',
				device_detal_list: [],
				//设备详情
				equipmentNumber: ''
			};
		},
		onLoad(e) {
			//上页面传来的 设备编号
			this.equipmentNumber = e.equipmentNumber
			console.log(e, '设备编号');

		},
		onShow() {
			//获取设备详情
			this.getdevice_detal()
		},
		methods: {
			//输入位置描述
			input_position(e) {
				this.input_text = e.detail.value
				console.log(e.detail.value);
			},
			getdevice_detal() {
				this.$https.get("system/equipment/equipmentdetails", {
					equipmentNumber: this.equipmentNumber
				}).then(res => {
					this.device_detal_list = res.rows[0]
					console.log(this.device_detal_list, '设备详情数据');
				})
			},
		}
	}
</script>

<style lang="scss">

</style>
